/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.jl.tools.stkeditor.generate;

import com.jl.tools.stkeditor.exception.DataNotMatchCodingScheamException;

import java.util.List;

/**
 *
 * @author LuHongjun
 */
public final class AddNote extends CodeDect {
  
  
  private String note;
  public AddNote(Code code,String note){
    this.code = code;
    this.note = "    //" + note + "\n";
  }

  @Override
  public List<String> getCode() throws DataNotMatchCodingScheamException {
    List<String> l = code.getCode();
    l.add(0,note);
    return l;
  }

  @Override
  public int getLength() {
    return code.getLength();
  }
  
}
